<extend name="Public:base" />

<block name="content-wrapper">
	<!-- Content Wrapper. Contains page content -->
	<div class="content-wrapper">
		<!-- Content Header (Page header) -->
		<section class="content-header">
			<h1>
				加入逻辑班级
				<small>Add Logic Class</small>
			</h1>
			<ol class="breadcrumb">
				<li>
					<a href="{:U('Index/index')}"> <i class="fa fa-dashboard"></i>
						首页
					</a>
				</li>
				<li>
					<a href="{:U('LogicClass/index')}">我的逻辑班级</a>
				</li>
				<li class="active">加入逻辑班级</li>
			</ol>
		</section>

		<!-- Main content -->
		<section class="content">
			<div class="row col-sm-6 col-sm-offset-3">
				<div class="box">
					<div class="box-header with-border">
						<h3 class="box-title">表单</h3>
					</div>
					<!-- /.box-header -->
					<!-- form start -->
					<div class="box-body">
						<form id="form-join" class="form-horizontal" action="{:U('MyLogicClass/joinPost')}" method="post">
							<div class="form-group">
								<label class="col-sm-2 control-label">逻辑班级</label>
								<div class="col-sm-9">
									<select name="logic_class_id" id="logic_class_id" class="form-control">
										<volist name="logic_classes" id="vo">
					                    	<option value="{$vo.id}">{$vo.academy.name}&nbsp;&nbsp;{$vo.name}</option>												
										</volist>
					                 </select>
								</div>
							</div>
						</form>
					</div>
					<!-- /.box-body -->
					<div class="box-footer">
						<a href="{:U('MyLogicClass/index')}" type="button" class="btn btn-default">返回</a>
						<button id="button-join-submit" type="button" class="btn btn-info pull-right">确定</button>
					</div>
					<!-- /.box-footer -->
				</div>				
			</div>

		</section>
		<!-- /.content -->
	</div>
	<!-- /.content-wrapper -->
</block>

<block name="additional-scripts">
	<script>
		$(function () {
			$('#button-join-submit').click(function() {
				$('#form-join').submit();
			});
		});
	</script>
</block>